package com.itheima.dao;

<<<<<<< HEAD
import org.apache.ibatis.annotations.Param;

import java.util.List;

import com.github.pagehelper.Page;
import com.itheima.pojo.Order;
import com.itheima.pojo.Setmeal;

import java.util.Date;
import java.util.Map;

public interface OrderDao {

    Page<Map<String, Object>> findByCondition
            (@Param("startDate") Date startDate, @Param("endDate") Date endDate, @Param("orderType") String orderType,
             @Param("orderStatus") String orderStatus, @Param("setmealName") String setmealName,
             @Param("nameOrPhoneNum") String nameOrPhoneNum);

    List<String> findAllSetmealName();

    List<Setmeal> findAll();

    List<Order> findOrderInfoByCondition(Order order);

    void add(Order order);

    Map<String, Object> findById(Integer id);

    List<Integer> findSetmealById(Integer id);

    void edit(Order order);

    void delete(Integer id);

    Order findOrderStatusById(Integer id);

    void updateOrderStatus(@Param("id") Integer id ,@Param("orderStatus") String orderStatus);

    Integer findOrderCountByDate(String month);

    Integer findVisitsCountByDate(String month);


    List<Integer> findSetmealIdByDate(String month);

    List<Integer> findSetmealData(@Param("start") String start, @Param("end") String end);

}
